﻿@using WebEntities
@using WebsiteUI.Extensions;
@model WI_News
@{
    string newsTitle = (Model == null) ? string.Empty : Model.NewsTitle;
    ViewBag.Title = newsTitle + "_城市垃圾处理网";
    string random = new Random().Next(1, 10).ToString();
    ViewBag.ClassHead = "head_bg" + random;
}
<div class="listMain">
    <div class="main_l">
        @Html.Action("CircleMenu", "PublicPartialView", new { id = (int)ViewBag.ArgID })
        @*<div class="CataArea">
            <div class="cata-box">
                <div class="tit">
                    资讯动态</div>
                <ul>
                    <li class="current"><i>·</i><a href="#">协会动态</a></li>
                    @for (int i = 0; i < 5; i++)
                    {
                        <li><i>·</i><a href="#">协会动态</a></li>
                    }
                </ul>
            </div>
        </div>
        <div style="height: 180px;">
        </div>*@
        <div class="contentBox">
            <div class="con_bar">
                <span class="fl tit">最新资讯动态</span>
                <div class="cls">
                </div>
            </div>
            <div class="con_Main_2">
                <ul>
                    @{
                        List<WI_News> ltnewsLst = ViewBag.LeftNewsList as List<WI_News>;
                        foreach (var news in ltnewsLst)
                        {
                        <li><a href="/detail/index/@news.NewsID" target="_blank">@news.NewsTitle</a> [@((news.PubTime ?? news.CreateTime).ToString("yyyy-MM-dd"))]</li>
                        }
                    }
                </ul>
            </div>
        </div>
        @Html.Action("Contact", "PublicPartialView")
    </div>
    <div class="main_r">
        @Html.Action("PageCurrentPath", "PublicPartialView", new { id = ViewBag.ArgID })
        <div class="contentBox ctb">
            <h1 class="tit">@Model.NewsTitle</h1>
            <div class="subMsg">
                <span>时间：@((Model.PubTime ?? Model.CreateTime).ToString("yyyy-MM-dd"))</span>@if (!string.IsNullOrEmpty(@Model.Publisher))
                                                                                             {<span>作者:@Model.Publisher</span>}
                @if (!string.IsNullOrEmpty(@Model.NewsSrc))
                {<span>来源:@Model.NewsSrc</span>}<span>阅读次数：@(Model.ViewCount ?? 0)次</span></div>
            <div class="cb_mainText">
                @Html.Raw(Server.HtmlDecode(Model.Description))
                @if (!string.IsNullOrWhiteSpace(Model.NewsFile))
                {
                    int docId = CommonFn.GetContentID("IndustryDocID");
                    <div>
                        附件链接：
                        @if (Model.CataID == docId)
                        {
                            if (Request.IsAuthenticated)
                            {
                            <a href="@Model.NewsFile">@((string.IsNullOrWhiteSpace(Model.FileTitle)) ? "附件1" : Model.FileTitle)</a>
                            }
                            else
                            {
                            <span>下载论文需要<a href="/home/login?repath=/detail/index/@Model.NewsID">登录</a>网站</span>
                            }
                        }
                        else
                        {
                            <a href="@Model.NewsFile">@((string.IsNullOrWhiteSpace(Model.FileTitle)) ? "附件1" : Model.FileTitle)</a>
                        }
                    </div>
                }
            </div>
            <div class="sharebar">
                <div style="float: left; line-height: 2em">
                    分享到:</div>
                <div id="bdshare" class="bdshare_t bds_tools get-codes-bdshare" style="float: left;
                    line-height: 2em">
                    <a class="bds_qzone"></a><a class="bds_tsina"></a><a class="bds_tqq"></a><a class="bds_renren">
                    </a><span class="bds_more">更多</span> <a class="shareCount"></a>
                </div>
                <script type="text/javascript" id="bdshare_js" data="type=tools&mini=1"></script>
                <script type="text/javascript" id="bdshell_js"></script>
                <script type="text/javascript">
                    /**
                    * 在这里定义bds_config
                    */
                    var bds_config = {
                        'bdText': '#架起政府与企业的桥梁，共建幸福广东#@Model.NewsTitle',
                        'review': 'off',
                        'snsKey': { 'tsina': '2890612191', 'tqq': '801062221'}		//'请参考自定义分享到平台的appkey'
                    }
                    document.getElementById("bdshell_js").src = "http://bdimg.share.baidu.com/static/js/shell_v2.js?cdnversion=" + new Date().getHours();
                </script>
            </div>
            <div class="cls">
            </div>
            <div class="keyword">
                <strong>关键词</strong>：@Model.Keywords
            </div>
            <div class="otherTxtLink">
                <ul>
                    @{
                        List<WI_News> botnewsLst = ViewBag.BotNewsList as List<WI_News>;
                        foreach (var news in botnewsLst)
                        {
                        <li><a href="/detail/index/@news.NewsID" title="@news.NewsTitle">@news.NewsTitle</a></li>
                        }
                    }
                </ul>
            </div>
        </div>
    </div>
</div>
